package register;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.beans.factory.annotation.Value;
import org.springframework.stereotype.Component;

@Component("user")
public class User {
    @Value("123")
    private String number;
    @Value("123")
    private String password;
    @Value("学生")
    private String id;

    public String getNumber() {
        return number;
    }

    public String getPassword() {
        return password;
    }

    public String getId() {
        return id;
    }

    public void setNumber(String number) {
        this.number = number;
    }

    public void setPassword(String password) {
        this.password = password;
    }

    public void setId(String id) {
        this.id = id;
    }

    @Override
    public String toString() {
        return "User{" +
                "number='" + number + '\'' +
                ", password='" + password + '\'' +
                ", id='" + id + '\'' +
                '}';
    }


    public void show(){
        System.out.println("注册成功--number:"+number+" password:"+password+" id:"+id);
    }
}
